#include<iostream>
#include<vector>
#include<time.h>
#include<set>
#include<unordered_set>
using namespace std;
void test()
{
  set<int>s;
  unordered_set<int>us;
  vector<int>v1;
  int N=100000;
  v1.reserve(N);
  srand(time(0));
  for(int i=0;i<N;i++)
  {
    v1.push_back(rand());
  }
  size_t begin1=clock();
  for(auto e :v1)
  {
    s.insert(e);
  }
  size_t end1=clock();
  size_t begin2=clock();
  for(auto u:us)
  {
    us.insert(u);
  }
  size_t end2=clock();
  cout<<"set:"<<end1-begin1<<endl;
  cout<<"unset:"<<end2-begin2<<endl;
}
int main()
{
  test();
  return 0;
}
